package com.gdkm.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.EnableTransactionManagement;

import com.gdkm.dao.MedicalDao;
import com.gdkm.dao.PrescriptionDao;
import com.gdkm.po.Medical;
import com.gdkm.service.MedicalService;
@EnableTransactionManagement
@Service
public class MedicalServiceImpl implements MedicalService {
	@Autowired
	MedicalDao dao;
	@Override
	public void save1(String m_name, String m_type, String m_symptom, String m_grade, String m_phone, String m_sex,
			String dateOfOnSet, String dateOfConsultation) {
		// TODO Auto-generated method stub
        dao.save1(m_name, m_type, m_symptom, m_grade, m_phone, m_sex, dateOfOnSet, dateOfConsultation);
	}

	@Override
	public List<Medical> list2(int y, int ge) {
		// TODO Auto-generated method stub
		return dao.list2(y, ge);
	}

	@Override
	public List<Medical> list3(String m_name, String m_grade, int y, int ge) {
		// TODO Auto-generated method stub
		return dao.list3(m_name, m_grade, y, ge);
	}

	@Override
	public void delete1(int id) {
		// TODO Auto-generated method stub
              dao.delete1(id);
	}

	@Override
	public void update(Medical stu) {
		// TODO Auto-generated method stub
         dao.update(stu);
	}
	@Override
	public List<Medical> list4(String m_name) {
		// TODO Auto-generated method stub
		return dao.list4(m_name);
	}
}
